import constants from '../constants/index';

const {
    GET_RECRUIT_LIST_SUCCESS,
    GET_RECRUIT_LIST_FAILURE,
    GET_USER_IN_SUCCESS,
} = constants;

export default (state = {}, action) => {
    switch (action.type) {
        case GET_RECRUIT_LIST_SUCCESS:
            return {
                ...state,
                list: action.data,
            };
            case GET_USER_IN_SUCCESS:
                return {
                    ...state,
                    userIn: action.data,
                };
        default:
            return state;
    }
};
